<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateDicsTable extends Migration
{
    /**
     * Run the migrations.
     */
    public function up(): void
    {
        Schema::create('dics', function (Blueprint $table) {
//            $table->comment('字典');
            $table->bigIncrements('id');
            $table->string('diccode', 30)->unique()->comment('字典编码');
            $table->string('dicname', 60)->comment('字典名称');
            $table->string('dicmemo', 100)->nullable()->comment('字典备注');
            $table->string('edititem', 1)->default('1')->comment('是否允许编辑条目');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::dropIfExists('dics');
    }
};
